@mixin clearfix {
  &:after {
    content: "";
    display: table;
    clear: both;
  }
}

@mixin scrollBar {
  &::-webkit-scrollbar-track-piece {
    background: #d3dce6;
  }

  &::-webkit-scrollbar {
    width: 6px;
  }

  &::-webkit-scrollbar-thumb {
    background: #99a9bf;
    border-radius: 20px;
  }
}

@mixin relative {
  position: relative;
  width: 100%;
  height: 100%;
}

@mixin pct($pct) {
  width: #{$pct};
  position: relative;
  margin: 0 auto;
}

@mixin triangle($width, $height, $color, $direction) {
  $width: $width/2;
  $color-border-style: $height solid $color;
  $transparent-border-style: $width solid transparent;
  height: 0;
  width: 0;

  @if $direction==up {
    border-bottom: $color-border-style;
    border-left: $transparent-border-style;
    border-right: $transparent-border-style;
  }

  @else if $direction==right {
    border-left: $color-border-style;
    border-top: $transparent-border-style;
    border-bottom: $transparent-border-style;
  }

  @else if $direction==down {
    border-top: $color-border-style;
    border-left: $transparent-border-style;
    border-right: $transparent-border-style;
  }

  @else if $direction==left {
    border-right: $color-border-style;
    border-top: $transparent-border-style;
    border-bottom: $transparent-border-style;
  }
}

// 多行省略号
@mixin bov($num:2) {
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: $num;
  -webkit-box-orient: vertical;
  word-break: break-all;

}

@mixin flex($c: row) {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: $c;
}

@for $i from 1 through 50 {
  .fw-#{$i} {
      font-weight: ($i * 100) !important;
  }
  // 文本省略
  .ov-#{$i} {
      @include bov($i)
  }
  // 字体大小
  .fz-#{$i} {
      font-size: $i +  px !important;
  }
  // 行高
  .linh-#{$i} {
      line-height: $i +  px;
  }
  // 圆角
  .br-#{$i} {
    border-radius: $i +  px;
  }
  // 内边距
  .pa-#{$i} {
      padding: $i +  px;
  }
  // 上内边距 案例：pt-20 就是上边距20px
  .pt-#{$i} {
      padding-top: $i +  px;
  }
  .pr-#{$i} {
      padding-right: $i +  px;
  }
  .pb-#{$i} {
      padding-bottom: $i +  px;
  }
  .pl-#{$i} {
      padding-left: $i +  px;
  }
  .px-#{$i} {
      padding-left: $i +  px;
      padding-right: $i +  px;
  }
  .py-#{$i} {
      padding-top: $i +  px;
      padding-bottom: $i +  px;
  }
  // 外边距
  .ma-#{$i} {
      margin: $i +  px;
  }
  .mt-#{$i} {
      margin-top: $i +  px;
  }
  .mr-#{$i} {
      margin-right: $i +  px;
  }
  .mb-#{$i} {
      margin-bottom: $i +  px;
  }
  .ml-#{$i} {
      margin-left: $i +  px;
  }
  .mx-#{$i} {
      margin-left: $i +  px;
      margin-right: $i +  px;
  }
  .my-#{$i} {
      margin-top: $i +  px;
      margin-bottom: $i +  px;
  }
}

.pa-0{padding: 0;}
.ma-0{margin: 0;}

// 弹性盒子
.disFlx{
  display: flex;
}

// 弹性盒子，上下居中
.disFlxAC{
  display: flex;
  align-items: center;
}

// 弹性盒子，左右布局，上下居中
.disFlxJS{
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.flexEnd {
  justify-content: flex-end;
}
.felxWW{
  flex-wrap: wrap;
}

.disFlxCC{
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.shrink0{
  flex-shrink: 0;
}

// 文字居中
.tc{
  text-align: center;
}
.tr{
  text-align: right;
}
.colorSuccess{
  color: #67C23A;
}
.colorZS{
  color: #1890ff;
}
.color3{
  color: #333333;
}
.color6{
  color: #666666;
}
.color8{
  color: #808080;
}
.color9{
  color: #999999;
}
.colorF{
  color: #FFFFFF;
}
.colorRED{
  color: #F56C6C;
}
.colorY{
  color: rgb(187, 147, 19);
}
.bgf{
  background-color: #FFFFFF !important;
}
.bgf5{
  background-color: #f5f5f5 !important;
}
.borderT{
  border-top: solid 1px #F5F5F5;
}
.borderB{
  border-bottom: solid 1px #F5F5F5;
}
.cup{
  cursor: pointer;
}
.width100{
  width: 100%;
}

.printOrder {
  box-sizing: border-box;
  margin: 0 auto;
  color: #000;
  display: flex;
  flex-direction: column;
  width: 100%;
  min-height: 100%;
  font-size: 12px;

  .prescription {
    border: solid 1px #cfcfcf;
    flex: 1;
    display: flex;
    flex-direction: column;
    height: auto;
  }
  .bomTips{
    display: flex;
    align-items: center;
    justify-content: flex-end;
    .checkedBox{
      padding: 8px;
      border: solid 1px #cfcfcf;
      margin-left: 2px;
    }
  }
}

.printGrid {
  display: grid;
  gap: 10px 15px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 10px 0;
}

.materialsTag{
  background-color: #bb9313;
  color: #FFF;
  border-radius: 5px;
  height: 18px;
  line-height: 16px;
  padding: 2px 6px;
  margin-top: 5px;
}

.dottedLine{
  border-top: dashed 1px #e6ebf5;
}
.spanGird>span+span{
  margin-left: 15px;
}

.commonTitle{
  position: relative;
  &::before{
    position: absolute;
    top: 0;
    left: -14px;
    content: " ";
    width: 4px;
    height: 100%;
    background: #1890ff;
  }
}

.relative{
  position: relative;
}
.absolute{
  position: absolute;
}
